<div class="panel panel-default panel-intro">
    <div class="panel-heading">
        <div class="panel-lead"></div>
        <ul class="nav nav-tabs">
        <li class="active"><a href="#basic" data-toggle="tab">基础配置</a></li>
        <li class=""><a href="#dictionary" data-toggle="tab">文章内容</a></li>
    </ul>
    </div>
    <div class="panel-body">

        <form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
            <!--data-primary-key="code" data-source="customer.customer/index" data-field="username"  data-params='{"custom[status]":"normal","custom[type]":"1"}'-->
            <div id="myTabContent" class="tab-content">

                <div class="tab-pane fade active in" id="basic">

                    <div class="widget-body no-padding">

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Category_id')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-category_id" data-rule="required" data-source="category/selectpage" data-field="name" data-params='{"custom[status]":"1"}' class="form-control selectpage" name="row[category_id]" type="text" value="">
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Keywords')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-keywords" data-rule="required"  data-source="article.tags" data-field="name" data-params='{"custom[status]":"1"}' data-multiple="true" class="form-control selectpage" name="row[keywords]" type="text" value="">
                                <div style="margin-top:5px;">
                                    <a href="javascript:" class="btn btn-xs btn-info btn-tags"><i class="fa fa-magic"></i>添加{:__('Keywords')}</a>
                                </div>
                            </div>
                        </div>


                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Title')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-title" data-rule="required" class="form-control" name="row[title]" type="text">
                                <p class="help-block-text" id="text_show">
                                </p>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Title_color')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="input-group">
                                    <input id="c-title_color" data-rule="required" class="form-control" name="row[title_color]" type="text" value="#0e0d0d">
                                    <span class="input-group-btn">
                                        <button type="button" class="btn btn-default btn-color" id="c-background" style="padding:0;margin-left:1px;" >
                                        </button>
                                        </span>
                                </div>
                            </div>
                        </div>

                        <div class="form-group">
                            <label for="c-image" class="control-label col-xs-12 col-sm-2">{:__('Img_url')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="input-group">
                                    <input id="c-image" class="form-control" data-rule="required" size="35" name="row[img_url]" type="text" value="">
                                    <div class="input-group-addon no-border no-padding">
                                        <span><button type="button" id="plupload-image" class="btn btn-danger plupload" data-url="common/UpArticlePic" data-input-id="c-image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="false" data-preview-id="p-image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                                        <span><button type="button" id="fachoose-image" class="btn btn-primary fachoose" data-input-id="c-image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
                                    </div>
                                    <span class="msg-box n-right"></span>
                                </div>
                                <ul class="row list-inline plupload-preview" id="p-image"></ul>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Description')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <textarea id="c-description" data-rule="" class="form-control" rows="2" name="row[description]" cols="50"></textarea>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Author')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-author" data-rule="required" class="form-control" name="row[author]" type="text" value="技术丶小贺">
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Is_top')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="radio">
                                    {foreach name="isTopList" item="vo"}
                                    <label for="row[is_top]-{$key}"><input id="row[is_top]-{$key}" name="row[is_top]" type="radio" value="{$key}" {in name="key" value="0"}checked{/in} /> {$vo}</label>
                                    {/foreach}
                                </div>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Is_show')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="radio">
                                    {foreach name="isShowList" item="vo"}
                                    <label for="row[is_show]-{$key}"><input id="row[is_show]-{$key}" name="row[is_show]" type="radio" value="{$key}" {in name="key" value="1"}checked{/in} /> {$vo}</label>
                                    {/foreach}
                                </div>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="radio">
                                    {foreach name="statusList" item="vo"}
                                    <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="row[status]" type="radio" value="{$key}" {in name="key" value="1"}checked{/in} /> {$vo}</label>
                                    {/foreach}
                                </div>

                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Is_recommend')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="radio">
                                    {foreach name="isRecommendList" item="vo"}
                                    <label for="row[is_recommend]-{$key}"><input id="row[is_recommend]-{$key}" name="row[is_recommend]" type="radio" value="{$key}" {in name="key" value="0"}checked{/in} /> {$vo}</label>
                                    {/foreach}
                                </div>

                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Is_tui')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <div class="radio">
                                    {foreach name="isTuiList" item="vo"}
                                    <label for="row[is_tui]-{$key}"><input id="row[is_tui]-{$key}" name="row[is_tui]" type="radio" value="{$key}" {in name="key" value="0"}checked{/in} /> {$vo}</label>
                                    {/foreach}
                                </div>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Origin')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                {:build_radios('row[origin]', ['原创'=>__('原创'), '转载'=>__('转载')])}
                            </div>
                        </div>
                      <!--  <div class="form-group origin" style="display: none;">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Url')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-url" class="form-control" name="row[url]" type="text" value="">
                                <p class="help-block-text text-success">
                                    * 文章转载的地址
                                </p>
                            </div>
                        </div>-->
                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Hits')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-hits" data-rule="required" class="form-control" name="row[hits]" type="number" value="{:mt_rand(0,50)}">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Love')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-love" data-rule="required" class="form-control" name="row[love]" type="number" value="{:mt_rand(5,100)}">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="control-label col-xs-12 col-sm-2">{:__('Comment_num')}:</label>
                            <div class="col-xs-12 col-sm-8">
                                <input id="c-comment_num" data-rule="required" class="form-control" name="row[comment_num]" type="number" value="{:mt_rand(5,90)}">
                            </div>
                        </div>


                        <div class="form-group layer-footer">
                            <label class="control-label col-xs-12 col-sm-2"></label>
                            <div class="col-xs-12 col-sm-8">
                                <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
                                <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
                            </div>
                        </div>

                    </div>

                </div>

                <div class="tab-pane fade" id="dictionary">

                    <div class="widget-body no-padding">

                        <div class="form-group">
                            <div class="col-xs-12 col-sm-12">
                                <p class="help-block-text text-warning">
                                    * 内容只支持markdown语法！！！
                                </p>
                                <textarea id="c-content" data-rule="required" class="form-control editor" rows="20" name="row[content]" cols="90"></textarea>
                            </div>
                        </div>

                    </div>

                </div>

            </div>


        </form>
    </div>

</div>






